package com.ncucoder.soms.dao;

import com.ncucoder.soms.entity.Role;

import java.util.Set;

/**
 * @author <a href="https://www.ncucoder.com">hsowan</a>
 * @date 2019-07-23
 */
public interface RoleMapper {
    int deleteById(Long id);

    int insert(Role record);

    Role selectById(Long id);

    int updateById(Role record);

    /**
     * 通过userId获取roles
     *
     * @param userId
     * @return
     */
    Set<String> listRolesByUserId(Long userId);


}